﻿// /////////////////////////////////// 
//  
//  
//      WiseLink CCF2.0 
//     (c)Copyright 2001-2010 WiseLink Xiaojun (David) Chen 
//        Authored and Owned Xiaojun (David) Chen 
//        All Right Reserved
//  
// /////////////////////////////////// 

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CCF20Model.ConfigurationFile;
using WiseLink.RDS.Resource;
using CCF20Module;

namespace CCF20
{
    public enum ViewModleType
    {
        LoginWindow,
        DeviceWindow,
        CustomerWindow
    }
    public class ViewModelFactory
    {
        
        public static object CreateViewModel(ViewModleType viewType)
        {
            switch (viewType)
            {
                case ViewModleType.LoginWindow:
                    if (ConfiguraitonHelper.MyConfiguration.customertype == ZICType.ChinaMobile)
                    {
                        return new ChinaMobileLoginWindowViewModel();
                    }
                    else if (ConfiguraitonHelper.MyConfiguration.customertype == ZICType.eRDS)
                    {
                        return new LoginWindowViewModel();
                    };
                    break;

            }
            throw new ArgumentException("Fained to create view model");

        }
    }
}
